// extract module
var connect = require('connect');

// create server
var server = connect.createServer();

// use logger
server.use(connect.logger());

// put request event handler
server.use(function(request, response) {
	// respond
	response.writeHead(200, {'Content-Type': 'text/html'});
	response.end('<h1>Hello Connect Module!</h1>');
});

// use error handler
server.use(connect.errorHandler({
	stack: true,
	message: true,
	dump: true
}));

// run server
server.listen(52273, function() {
	console.log('Server running at http://127.0.0.1:52273');
});